NonFatal

object NonFatal

Matcher for non-fatal Throwables.

Note: AssertionError is not matched by NonFatal, as it's intended to be thrown iff the assumptions about the code are false.

Note: NotImplementedError is not matched by NonFatal, as it's intended to indicate a method that remains to be implemented.

Since

1.4.30

object NonFatal

Matcher for non-fatal Throwables.

Note: AssertionError is not matched by NonFatal, as it's intended to be thrown iff assumptions about the code are false.

Note: NotImplementedError is not matched by NonFatal, as it's intended to indicate a method that remains to be implemented.

Since

1.4.30

object NonFatal

Matcher for non-fatal Throwables. Will not match fatal errors like VirtualMachineError (for example, OutOfMemoryError, subclass of VirtualMachineError), ThreadDeath, LinkageError, InterruptedException.

Note: AssertionError is not matched by NonFatal, as it's intended to be thrown iff the assumptions about the code are false.

Note: NotImplementedError is not matched by NonFatal, as it's intended to indicate a method that remains to be implemented.

Since

1.4.30

object NonFatal

Matcher for non-fatal Throwables. Will not match fatal errors like OutOfMemoryError.

Note: AssertionError is not matched by NonFatal, as it's intended to be thrown iff the assumptions about the code are false.

Note: NotImplementedError is not matched by NonFatal, as it's intended to indicate a method that remains to be implemented.

Since

1.4.30

Functions

invoke
Link copied to clipboard
common
operator fun invoke(exception: Throwable): Boolean
Returns true if the provided Throwable is to be considered non-fatal, or false if it is to be considered fatal.
js
operator fun invoke(exception: Throwable): Boolean
Returns true if the provided Throwable is to be considered non-fatal, or false if it is to be considered fatal.
operator fun invoke(exception: Throwable): Boolean
Returns true if the provided Throwable is to be considered non-fatal, or false if it is to be considered fatal.
native
operator fun invoke(exception: Throwable): Boolean
Returns true if the provided Throwable is to be considered non-fatal, or false if it is to be considered fatal.